Export this privately.
authorMatthias Clasen <mclasen@redhat.com>
Thu, 20 Jul 2006 18:07:21 +0000 (18:07 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Thu, 20 Jul 2006 18:07:21 +0000 (18:07 +0000)
2006-07-20  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkicontheme.h:
* gtk/gtkicontheme.c (_gtk_icon_theme_ensure_builtin_cache):
Export this privately.

* gtk/gtkiconfactory.c (render_fallback_image): And call it
here to initialize the builtin cache before using it.  (#348063,
Diego Pettenò)

ChangeLog
ChangeLog.pre-2-10
gtk/gtkiconfactory.c
gtk/gtkicontheme.c
gtk/gtkicontheme.h

index 7c1e57b9be44553db43cfc08c4ab3c4a270127a8..83cd8a1303cd6a1b8450d8a24905f22f0f9e5f02 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2006-07-20  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkicontheme.h: 
+       * gtk/gtkicontheme.c (_gtk_icon_theme_ensure_builtin_cache): 
+       Export this privately.
+
+       * gtk/gtkiconfactory.c (render_fallback_image): And call it
+       here to initialize the builtin cache before using it.  (#348063,
+       Diego Pettenò)
+
 2006-07-19  Federico Mena Quintero  <federico@novell.com>
 
        * tests/autotestfilechooser.c (test_black_box): Argh, initialize
index 7c1e57b9be44553db43cfc08c4ab3c4a270127a8..83cd8a1303cd6a1b8450d8a24905f22f0f9e5f02 100644 (file)
@@ -1,3 +1,13 @@
+2006-07-20  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkicontheme.h: 
+       * gtk/gtkicontheme.c (_gtk_icon_theme_ensure_builtin_cache): 
+       Export this privately.
+
+       * gtk/gtkiconfactory.c (render_fallback_image): And call it
+       here to initialize the builtin cache before using it.  (#348063,
+       Diego Pettenò)
+
 2006-07-19  Federico Mena Quintero  <federico@novell.com>
 
        * tests/autotestfilechooser.c (test_black_box): Argh, initialize
index 55ea92bdea5d28137687d094ae5f65bc472d5adf..4c04b9379048eed054bde8ad10678542a055f466 100644 (file)
@@ -1566,9 +1566,13 @@ render_fallback_image (GtkStyle          *style,
 
   if (fallback_source.type == GTK_ICON_SOURCE_EMPTY)
     {
-      GdkPixbuf *pixbuf = _gtk_icon_cache_get_icon (_builtin_cache,
-                                                   GTK_STOCK_MISSING_IMAGE,
-                                                   "24");
+      GdkPixbuf *pixbuf;
+
+      _gtk_icon_theme_ensure_builtin_cache ();
+
+      pixbuf = _gtk_icon_cache_get_icon (_builtin_cache,
+                                        GTK_STOCK_MISSING_IMAGE,
+                                        "24");
       gtk_icon_source_set_pixbuf (&fallback_source, pixbuf);
       g_object_unref (pixbuf);
     }
index cffb892e908e19a3af1fb7898c6244ec86894375..ebfc282a4626190887e41c2ce5b10ebafba7c861 100644 (file)
@@ -1129,7 +1129,7 @@ load_themes (GtkIconTheme *icon_theme)
   priv->last_stat_time = tv.tv_sec;
 }
 
-static void
+void
 _gtk_icon_theme_ensure_builtin_cache (void)
 {
   static gboolean initialized = FALSE;
index 8190806d254eac5b8e635534eb312218ebb7db1d..1c607ad5809a1f23a408a3e49ab5c10505f05c90 100644 (file)
@@ -169,6 +169,7 @@ G_CONST_RETURN gchar *gtk_icon_info_get_display_name  (GtkIconInfo   *icon_info)
 
 /* Non-public methods */
 void _gtk_icon_theme_check_reload                     (GdkDisplay *display);
+void _gtk_icon_theme_ensure_builtin_cache             (void);
 
 G_END_DECLS